repo: [scan-build] Initialize a variable
authorColin Walters <walters@verbum.org>
Mon, 14 Oct 2019 14:17:09 +0000 (14:17 +0000)
committerColin Walters <walters@verbum.org>
Tue, 15 Oct 2019 12:41:27 +0000 (12:41 +0000)
Another GLib error convention issue; but eh, we might as
well be conservative and always initialize variables.

src/libostree/ostree-repo.c

index b654aff2a0b833511d8f4029b11dc2ff6da54e70..e2998f732e3e4e75ac90c58d5b93e5d4bafcf311 100644 (file)
@@ -4197,7 +4197,7 @@ ostree_repo_has_object (OstreeRepo           *self,
                         GCancellable         *cancellable,
                         GError              **error)
 {
-  gboolean ret_have_object;
+  gboolean ret_have_object = FALSE;
 
   if (!_ostree_repo_has_loose_object (self, checksum, objtype, &ret_have_object,
                                       cancellable, error))